home *** CD-ROM | disk | FTP | other *** search
/ PC Player 2004 May / pc player 2004-05.iso / Demos / FarCry / Data1.cab / _C7DD2D9EE8C047BAB6D31D0C64A3FD23 < prev    next >
Encoding:
Text File  |  2004-01-06  |  2.1 KB  |  85 lines

  1.  
  2. AIBehaviour.Car_goto = {
  3.     Name = "Car_goto",
  4.     
  5.  
  6.     -- SYSTEM EVENTS            -----
  7.     ---------------------------------------------
  8.     OnSpawn = function(self , entity )
  9.  
  10.     end,
  11.     ---------------------------------------------
  12.     OnActivate = function(self, entity )
  13.         self.allowed = 1;
  14.     end,
  15.     ---------------------------------------------
  16.     OnNoTarget = function(self, entity )
  17. --        entity:SelectPipe(0,"return_to_start");
  18.     end,
  19.  
  20.     ---------------------------------------------
  21.     OnEnemyMemory = function( self, entity )
  22.  
  23. --        entity:TriggerEvent(AIEVENT_REJECT);
  24.  
  25.     end,
  26.  
  27.     --------------------------------------------
  28.     OnPlayerSeen = function( self, entity, fDistance )
  29.  
  30. --        entity:TriggerEvent(AIEVENT_REJECT);
  31.  
  32.     end,
  33.  
  34.     ---------------------------------------------
  35.     ---------------------------------------------
  36.     OnGroupMemberDied = function( self,entity,sender )
  37. --do return end
  38. --printf( "Vehicle -------------- OnDeath" );    
  39.         if( sender == entity.driver ) then                -- stop if the driver is killed
  40.             AI:Signal( 0, 1, "DRIVER_OUT",entity.id);
  41.         end    
  42.     end,    
  43.  
  44.     ---------------------------------------------
  45.     OnPlayerMemory = function(self, entity )
  46.     end,
  47.     ---------------------------------------------
  48.     OnEnemySeen = function(self, entity )
  49.     end,
  50.     ---------------------------------------------
  51.     OnDeadFriendSeen = function(self,entity )
  52.     end,
  53.     ---------------------------------------------
  54.     OnGranateSeen = function(self, entity )
  55.     
  56.         entity:InsertSubpipe(0,"c_grenade_run_away" );    
  57.     
  58.     end,
  59.     ---------------------------------------------
  60.     OnDied = function( self,entity )
  61.     end,
  62.     ---------------------------------------------
  63.     ---------------------------------------------
  64.     
  65.  
  66.     -- CUSTOM
  67.     ---------------------------------------------
  68.     
  69.  
  70.     ---------------------------------------------
  71.     DRIVER_OUT = function( self,entity,sender )
  72. --printf( "car patol  -------------- driver out" );    
  73.         entity:SelectPipe(0,"c_brake" );
  74.         entity:DropPeople();        
  75.     end,    
  76.  
  77.  
  78.     --------------------------------------------
  79.     next_point = function( self,entity, sender )
  80. System:LogToConsole( "carGoto NEXTPOINT" );
  81.         entity:SelectPipe(0,"c_standingthere");
  82.     end,
  83.  
  84. }
  85.